import service from '@/utils/request'

export const useJarPackageApi = (id: number) => {
	return service.get('/data-development/jar/' + id)
}

export const useJarPackageSubmitApi = (dataForm: any) => {
	if (dataForm.id) {
		return service.put('/data-development/jar', dataForm)
	} else {
		return service.post('/data-development/jar', dataForm)
	}
}

export const deleteJarPackageApi = (id: number) => {
	return service.delete('/data-development/jar/' + id)
}

export const jarPageApi = params => {
	return service.get('/data-development/jar/page?' + params)
}
export const jarRunTypeApi = (jarRunType: number) => {
	return service.get('/data-development/jar/list/' + jarRunType)
}
